jQuery(document).ready(function(){
        //====================
        // for recommond items
        //====================
        jQuery(".recommond-item_detail").on("click", function(event){
            //alert(event.target);
            var x = jQuery(event.target).siblings(".strategy_id_cls").text();
            //alert(x);
            window.location.href="/tactics_detail?id="+x;
        });

        //=========================
        // for hot items (option 1)
        //=========================
        jQuery(".strategy_name_cls").on("click", function(event){
            //alert(event.target);
            var x = jQuery(this).next().next().children("#strategy_id2").text();
            //alert(x);
            window.location.href="/tactics_detail?id="+x;
        });
        jQuery(".strategy_keys_cls").on("click", function(event){
            var x = jQuery(this).next().children("#strategy_id2").text();
            window.location.href="/tactics_detail?id="+x;
        });
        jQuery(".strategy_values_cls").on("click", function(event){
            var x = jQuery(this).children("#strategy_id2").text();
            window.location.href="/tactics_detail?id="+x;
        });

        //==================================================
        // href to tactics-detail for hot-tactics (option 2)
        //==================================================
        jQuery(".hot-tactics-item").on("click", function(event){
            //alert(this.nodeName);
            var x = jQuery(this).children(".hot-tactics-row2").children(".strategy_id_cls").text();
            //alert(x);
            window.location.href="/tactics_detail?id="+x;
        });

        //=============================================
        // href to tactics-detail for recommond-tactics
        //=============================================
        jQuery(".recommond-item").on("click", function(event){
            //alert("THIS IS RECOMMOND-ITEM"+event.target);
            var x = jQuery(this).children(".strategy_id_cls").text();
            //alert(x);
            window.location.href="/tactics_detail?id="+x;
        });
        
        //=======================================
        // href to tactics-detail for all-tactics
        //=======================================
        jQuery(".strategy_name_cls").on("click", function(event){
            //alert(event.target);
            var x = jQuery(this).next().next().children(".strategy_cls2").text();
            //alert(x);
            window.location.href="/tactics_detail?id="+x;
        });
        jQuery(".strategy_keys_cls").on("click", function(event){
            //alert(event.target);
            var x = jQuery(this).next().children(".strategy_cls2").text();
            //alert(x);
            window.location.href="/tactics_detail?id="+x;
        });
        jQuery(".strategy_values_cls").on("click", function(event){
            //alert(event.target);
            var x = jQuery(this).children(".strategy_cls2").text();
            //alert(x);
            window.location.href="/tactics_detail?id="+x;
        });
});
